//
//  InteractionBarItem.m
//  IntelligenceCommunity
//
//  Created by zhangpei on 16/1/18.
//  Copyright © 2016年 zhangpei. All rights reserved.
//

#import "InteractionBarItem.h"

@interface InteractionBarItem()
{
    
}

@end

@implementation InteractionBarItem

@synthesize title, icon, operType, isValid;

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    
    if (self)
    {
        self.backgroundColor = [UIColor clearColor];
        
        operType = -1;
        isValid = -1;
        
        [self initView];
    }
    
    return self;
}


- (void)initView
{
    title = [[UILabel alloc] initWithFrame:CGRectMake(0, 0.6*self.bounds.size.height, self.bounds.size.width, 0.3*self.bounds.size.height)];
    
    title.backgroundColor = [UIColor clearColor];
    
    title.textAlignment = NSTextAlignmentCenter;
    
    title.font = [UIFont systemFontOfSize:12];
    
    title.textColor = [UIColor colorWithRed:170/255 green:170/255 blue:170/255 alpha:1];
    
    [self addSubview:title];
    
    icon = [[UIImageView alloc] init];
    
    icon.backgroundColor = [UIColor clearColor];
    
    icon.contentMode = UIViewContentModeScaleAspectFit;
    
    [self addSubview:icon];
}





@end
